package com.wangjiang.mario.admin.common.base;

import com.wangjiang.mario.admin.common.rest.ResultGenerator;
import com.wangjiang.mario.admin.common.rest.entity.Result;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

import java.lang.reflect.ParameterizedType;

/**
 * 通用查询控制器
 *
 * @param <T> 实体类
 * @param <Q> 查询类，用于列表查询
 * @param <V> 实体类的返回类
 */
public class BaseParentSearchController<T extends BaseSortParentEntity, Q extends BaseQo, V extends BaseVo> extends BaseSearchController<T, Q, V>{

    @GetMapping("/tree")
    public Result tree (T qo) {
        return ResultGenerator.genSuccessResult(baseService.tree(qo));
    }
}
